package magicloan.auctionpocket.adapter;

import android.content.Context;
import android.support.annotation.Nullable;
import android.widget.TextView;
import com.chad.library.adapter.base.BaseMultiItemQuickAdapter;
import com.chad.library.adapter.base.BaseViewHolder;
import java.util.List;
import magicloan.auctionpocket.R;
import magicloan.auctionpocket.bean.ProductDetailBean;

/**
 * Created by hechao on 2018/1/31.
 */
public class ProductDetailAdapter extends BaseMultiItemQuickAdapter<ProductDetailBean, BaseViewHolder> {

    private final int ThreeImg = 0 ;
    private final int OneImg = 1 ;

    public ProductDetailAdapter(@Nullable List<ProductDetailBean> data) {
        super(data);
    }

    @Override
    protected void convert(BaseViewHolder viewHolder, ProductDetailBean item, int position) {
        TextView tv_text = viewHolder.getView(R.id.tv_text);
        switch (viewHolder.getItemViewType()) {
            case ThreeImg:
//                threeImg(viewHolder,item);
                break;
            case OneImg:
//                tv_text.setText("right  " + position );
//                oneImg(viewHolder,item);
                break;
        }
    }

    private TextView mLastTv ;

    public ProductDetailAdapter(Context context,List data) {
        super(data);
        addItemType(ThreeImg, R.layout.ac_productdetail_left);
        addItemType(OneImg,R.layout.ac_productdetail_right);
    }

}
